-
Notifications
You must be signed in to change notification settings - Fork 29.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
benchmark: fix fs\bench-realpathSync.js #11904
Conversation
Make it call-site-cwd-independent.
I've been running that benchmark quite a bit lately and haven't had problems running it outside of the benchmark/fs/ directory, including via benchmark/compare.js. How are you triggering the error exactly? |
|
Also:
|
@mscdex Is it OK to land this or should I provide more info? |
It's fine by me I guess. |
Landed in ab2d49b |
Make it call-site-cwd-independent. PR-URL: #11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Make it call-site-cwd-independent. PR-URL: nodejs#11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Not a big thing, but I'd just like to note for future reference that forward slashes are preferable in paths. |
@seishun Thank you. Sorry. |
Make it call-site-cwd-independent. PR-URL: #11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
This does not land cleanly in LTS. Please feel free to manually backport. Please also feel free to replace do-not-land if it is being backported edit: nvm it lands 🎉 |
Make it call-site-cwd-independent. PR-URL: #11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Make it call-site-cwd-independent. PR-URL: #11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Make it call-site-cwd-independent. PR-URL: nodejs/node#11904 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)
benchmark, fs
fs\bench-realpathSync.js
runs safely only if itscwd
is its__dirname
. In other cases, it throwsENOENT: no such file or directory
. This commit makes it callable from any place (including being a part of thefs
suite launched from any directory).